<!DOCTYPE html>
<html lang="zh-Hans" xmlns:th="http://www.thymeleaf.org">
<head>
	<title>诊断信息详情</title>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chorme=1">
    <meta name="renderer" content="webkit">
	<script src="/static/cqzd/js/boot.js"></script>
	<script src="/static/cqzd/js/national.js"></script>
</head>
<body>

<div id="tabs1" class="mini-tabs" activeIndex="0" style="width:100%;height:98%;" plain="false">
	<div title="患者基本信息" >
		<div style="padding-top:5px">
			<div id="diacrisis_form">
				<table style="width:100%;height:100%;table-layout:fixed;text-align: right;padding-right: 50px;line-height: 40px" class="mini-form-table" >
					<tr >
						<th class="mini-form-label"><label>门诊号：</label></th>
						<td >
							<input id="outpatientNo" name="outpatientNo" class="mini-textbox mini-form-input myInput" required="true" />
						</td>
						<th class="mini-form-label"><label>就诊日期：</label></th>
						<td>
							<input id="recordTime" name="recordTime" class="mini-datepicker  mini-form-input myInput"  format="yyyy-MM-dd H:mm:ss" timeFormat="H:mm:ss" showTime="true"/>
						</td>
						<th class="mini-form-label"><label>患者姓名：</label></th>
						<td>
							<input id="patientName" name="patientName" class="mini-textbox mini-form-input myInput"   />
						</td>


					</tr>
					<tr class="odd">

						<th class="mini-form-label"><label>身份证：</label></th>
						<td>
							<input id="patientCardId" name="patientCardId"  class="mini-textbox  mini-form-input myInput" />
						</td>

						<th class="mini-form-label"><label>出生日期：</label></th>
						<td>
							<input id="patientBirthday" name="patientBirthday" class="mini-datepicker mini-form-input myInput" />
						</td>


						<th class="mini-form-label"><label>民族：</label></th>
						<td>
							<input id="patientRaceId" name="patientRaceId" class="mini-combobox mini-form-input myInput" textfield="name"/>
						</td>

					</tr>

					<tr>
						<th class="mini-form-label"><label>宗教信仰：</label></th>
						<td>
							<input id="patientReligion" name="patientReligion" class="mini-textbox mini-form-input myInput "/>
						</td>

						<th class="mini-form-label"><label>年龄：</label></th>
						<td>
							<input id="patientAge" name="patientAge" class="mini-textbox mini-form-input myInput"/>
						</td>
						<th class="mini-form-label"><label>职业：</label></th>
						<td>
							<input id="patientOccupation" name="patientOccupation" class="mini-textbox  mini-form-input myInput" />
						</td>

					</tr>
					<tr>
						<th class="mini-form-label"><label>学历：</label></th>
						<td>
							<input id="patientEdu" name="patientEdu" class="mini-textbox  mini-form-input myInput"/>
						</td>

						<th class="mini-form-label"><label>配偶年龄：</label></th>
						<td>
							<input id="spouseAge" name="spouseAge" class="mini-textbox  mini-form-input myInput"/>
						</td>

						<th class="mini-form-label"><label>配偶职业：</label></th>
						<td>
							<input id="spouseOccupation" name="spouseOccupation" class="mini-textbox  mini-form-input myInput"/>
						</td>
					</tr>
					<tr>
						<th class="mini-form-label"><label>配偶学历：</label></th>
						<td>
							<input id="spouseEdu" name="spouseEdu" class="mini-textbox  mini-form-input myInput"/>
						</td>

						<th class="mini-form-label"><label>末次月经时间：</label></th>
						<td>
							<input id="lastMenses" name="lastMenses" class="mini-datepicker  mini-form-input myInput"/>
						</td>

						<th class="mini-form-label"><label>预产期：</label></th>
						<td>
							<input id="expectedDate" name="expectedDate" class="mini-datepicker  mini-form-input myInput"/>
						</td>
					</tr>
					<tr>
						<th class="mini-form-label"><label>怀孕次数：</label></th>
						<td>
							<input id="gestCount" name="gestCount" class="mini-textbox  mini-form-input myInput"/>
						</td>

						<th class="mini-form-label"><label>生产次数：</label></th>
						<td>
							<input id="prodCount" name="prodCount" class="mini-textbox  mini-form-input myInput"/>
						</td>

						<th class="mini-form-label"><label>流产次数：</label></th>
						<td>
							<input id="aboCount" name="aboCount" class="mini-textbox  mini-form-input myInput"/>
						</td>
					</tr>

					<tr>
						<th class="mini-form-label"><label>存活次数：</label></th>
						<td>
							<input id="liveCount" name="liveCount" class="mini-textbox  mini-form-input myInput"/>
						</td>

						<th class="mini-form-label"><label>孕龄周：</label></th>
						<td>
							<input id="gestWeeks" name="gestWeeks" class="mini-textbox  mini-form-input myInput"/>
						</td>

						<th class="mini-form-label"><label>孕龄天：</label></th>
						<td>
							<input id="gestDays" name="gestDays" class="mini-textbox  mini-form-input myInput"/>
						</td>
					</tr>

					<tr>
						<th class="mini-form-label"><label>受孕方式：</label></th>
						<td>
							<input id="impgTypeName" name="impgTypeName" class="mini-textbox  mini-form-input myInput"/>
						</td>

						<th class="mini-form-label"><label>家族史：</label></th>
						<td>
							<input id="familyMedical" name="familyMedical" class="mini-textbox  mini-form-input myInput"/>
						</td>

						<th class="mini-form-label"><label>特殊病史：</label></th>
						<td>
							<input id="specialMedical" name="specialMedical" class="mini-textbox  mini-form-input myInput"/>
						</td>
					</tr>

					<tr>
						<th class="mini-form-label"><label>不良孕产史：</label></th>
						<td>
							<input id="badGest" name="badGest" class="mini-textbox  mini-form-input myInput"/>
						</td>

						<th class="mini-form-label"><label>孕期用药史：</label></th>
						<td>
							<input id="drugUse" name="drugUse" class="mini-textbox  mini-form-input myInput"/>
						</td>

						<th class="mini-form-label"><label>用药史备注：</label></th>
						<td>
							<input id="drugUseRemark" name="drugUseRemark" class="mini-textbox  mini-form-input myInput"/>
						</td>
					</tr>

					<tr>
						<th class="mini-form-label"><label>胎类型：</label></th>
						<td>
							<input id="fetusesType" name="fetusesType" class="mini-textbox  mini-form-input myInput"/>
						</td>

						<th class="mini-form-label"><label>胎数：</label></th>
						<td>
							<input id="fetusesNo" name="fetusesNo" class="mini-textbox  mini-form-input myInput"/>
						</td>

						<th class="mini-form-label"><label>是否有效：</label></th>
						<td>
							<input id="isValid" name="isValid" class="mini-combobox  mini-form-input myInput" data="[{id:'1',text:'是'},{id:'2',text:'否'}]"/>
						</td>
					</tr>

					<tr>
						<th class="mini-form-label"><label>是否转诊：</label></th>
						<td>
							<input id="isTransfer" name="isTransfer" class="mini-combobox  mini-form-input myInput" data="[{id:'1',text:'是'},{id:'2',text:'否'}]"/>
						</td>

						<th class="mini-form-label"><label>预约内容：</label></th>
						<td>
							<input id="bespeakContent" name="bespeakContent" class="mini-textbox  mini-form-input myInput"/>
						</td>

						<th class="mini-form-label"><label>转诊省份：</label></th>
						<td>
							<input id="transferProvinceId" name="transferProvinceId" class="mini-combobox  mini-form-input myInput" textField="name" valueField="id"/>
						</td>
					</tr>
					<tr>
						<th class="mini-form-label"><label>转诊市区：</label></th>
						<td>
							<input id="transferCityId" name="transferCityId" class="mini-combobox  mini-form-input myInput" textField="name" valueField="id"/>
						</td>

						<th class="mini-form-label"><label>转诊区县：</label></th>
						<td>
							<input id="transferCountyId" name="transferCountyId" class="mini-combobox  mini-form-input myInput" textField="name" valueField="id"/>
						</td>

						<th class="mini-form-label"><label>患者住址：</label></th>
						<td>
							<input id="patientAddress" name="patientAddress" class="mini-textbox  mini-form-input myInput"/>
						</td>
					</tr>
					<tr>
						<th class="mini-form-label"><label>患者电话：</label></th>
						<td>
							<input id="patientTel" name="patientTel" class="mini-textbox  mini-form-input myInput"/>
						</td>

						<th class="mini-form-label"><label>配偶电话：</label></th>
						<td>
							<input id="spouseTel" name="spouseTel" class="mini-textbox  mini-form-input myInput"/>
						</td>

						<th class="mini-form-label"><label>诊断备注：</label></th>
						<td>
							<input id="diacrisisRemark" name="diacrisisRemark" class="mini-textbox  mini-form-input myInput"/>
						</td>
					</tr>
				</table>

			</div>
		</div>
	</div>

	<div title="现存孩信息" class="mini-tabs" >
		<div class="mini-fit" >
			<div id="existingChild_grid" class="mini-datagrid" style="width:100%;height:100%;" showPager='false'    >
				<div property="columns">
<!--					<div field="childBirthday" width="160" headerAlign="center" align="center" allowSort="false"  dateFormat="yyyy-MM-dd hh:mm:ss">小孩出生日期</div>-->
					<div field="childSex" width="120" headerAlign="center" align="center" allowSort="false" renderer="renderSex">性别</div>
					<div field="childAge" width="120" headerAlign="center" align="center" allowSort="false">年龄</div>
					<div field="childRemark" width="160" headerAlign="center" align="center" allowSort="false">备注</div>
				</div>
			</div>
		</div>
	</div>
	<div title="居住环境信息" class="mini-tabs">
		<div class="mini-fit" >
			<div id="live_grid" class="mini-datagrid" style="width:100%;height:100%;"   showPager='false'  >
				<div property="columns">
					<div field="patientLiveName" width="160" headerAlign="center" align="center" allowSort="false">居住环境</div>
				</div>
			</div>
		</div>
	</div>
	<div title="检验结果信息" class="mini-tabs">
		<div class="mini-fit"  >
			<div id="assay_grid" class="mini-datagrid" style="width:100%;height:100%;"  showPager='false'  >
				<div property="columns">
					<div field="niptTypeName" width="160" headerAlign="center" align="center" allowSort="false" >无创产前DNA检测</div>
					<div field="tangScreenName" width="120" headerAlign="center" align="center" allowSort="false" >唐筛名称</div>
					<div field="sbp" width="120" headerAlign="center" align="center" allowSort="false">收缩压</div>
					<div field="dbp" width="160" headerAlign="center" align="center" allowSort="false">舒张压</div>
					<div field="tpr" width="120" headerAlign="center" align="center" allowSort="false" >体温(°C)</div>
					<div field="bloodTypeName" width="120" headerAlign="center" align="center" allowSort="false">血型</div>
					<div field="btNatureName" width="160" headerAlign="center" align="center" allowSort="false">血型性级</div>
					<div field="antibodyNatureName" width="120" headerAlign="center" align="center" allowSort="false">不规则抗体性级</div>
					<div field="assayRemark" width="160" headerAlign="center" align="center" allowSort="false">备注</div>
				</div>
			</div>
		</div>
	</div>
	<div title="B超检查结果" class="mini-tabs" style="width:100%;height:100%;">
        <div class="mini-splitter" vertical="true" style="width:100%;height:100%;">
            <div size="40%" showCollapseButton="true">
                <div class="mini-fit" >
                    <div id="fetus_grid" class="mini-datagrid" style="width:100%;height:100%;"  showPager='false' onrowclick="fetusGridOnclick" >
                        <div property="columns">
                            <div field="inspectTime" width="160" headerAlign="center" align="center" allowSort="false"  dateFormat="yyyy-MM-dd hh:mm:ss">检查日期</div>
                            <div field="gestWeeks" width="120" headerAlign="center" align="center" allowSort="false" >孕龄周</div>
                            <div field="gestDays" width="120" headerAlign="center" align="center" allowSort="false">孕龄天</div>
                            <div field="inspectionHospital" width="160" headerAlign="center" align="center" allowSort="false">检查医院</div>
                            <div field="nt" width="120" headerAlign="center" align="center" allowSort="false" >NT</div>
                            <div field="crl" width="120" headerAlign="center" align="center" allowSort="false">CRL</div>
                            <div field="isNasal" width="160" headerAlign="center" align="center" allowSort="false" renderer="onIsyouwubigu">有无鼻骨</div>
                            <div field="siteName" width="120" headerAlign="center" align="center" allowSort="false">胎盘位置</div>
                            <div field="bAbnormal" width="160" headerAlign="center" align="center" allowSort="false">B超异常</div>
                            <div field="chorionicName" width="160" headerAlign="center" align="center" allowSort="false">绒毛膜性</div>
                            <div field="fetusRemark" width="160" headerAlign="center" align="center" allowSort="false">备注</div>
                        </div>
                    </div>
                </div>
            </div>
            <div showCollapseButton="true">
                <div class="mini-fit" >
                    <div id="fetusDetail_grid" class="mini-datagrid" style="width:100%;height:100%;"  showPager='false'  >
                        <div property="columns">
                            <div field="inspectionTime" width="160" headerAlign="center" align="center" allowSort="false"  dateFormat="yyyy-MM-dd hh:mm:ss">检查日期</div>
                            <div field="gestWeeks" width="120" headerAlign="center" align="center" allowSort="false" >孕龄周</div>
                            <div field="gestDays" width="120" headerAlign="center" align="center" allowSort="false">孕龄天</div>
                            <div field="inspectionHospital" width="160" headerAlign="center" align="center" allowSort="false">检查医院</div>
                            <div field="bpd" width="120" headerAlign="center" align="center" allowSort="false" >双顶径长度</div>
                            <div field="crl" width="120" headerAlign="center" align="center" allowSort="false">CRL</div>
                            <div field="isNasal" width="160" headerAlign="center" align="center" allowSort="false" renderer="onIsyouwubigu">有无鼻骨</div>
                            <div field="fl" width="120" headerAlign="center" align="center" allowSort="false">FL</div>
                            <div field="efw" width="160" headerAlign="center" align="center" allowSort="false">EFW</div>
                            <div field="afi" width="160" headerAlign="center" align="center" allowSort="false">AFI</div>
                            <div field="afv" width="160" headerAlign="center" align="center" allowSort="false">AFV</div>
                            <div field="bloodFlow" width="160" headerAlign="center" align="center" allowSort="false">血流</div>
                            <div field="umbilicalInsertion" width="160" headerAlign="center" align="center" allowSort="false">脐带插入</div>
                            <div field="siteName" width="160" headerAlign="center" align="center" allowSort="false">胎盘位置</div>
                            <div field="bAbnormal" width="160" headerAlign="center" align="center" allowSort="false">B超异常</div>
                            <div field="chorionicName" width="160" headerAlign="center" align="center" allowSort="false">绒毛膜性</div>
                            <div field="fetusDetailRemark" width="160" headerAlign="center" align="center" allowSort="false">备注</div>
                        </div>
                    </div>
                </div>
            </div>
	    </div>
	</div>
	<div title="病历查询" class="mini-tabs">
		<div class="mini-fit"  >
			<div id="file_grid" class="mini-datagrid" style="width:100%;height:100%;"  showPager='false'  >
				<div property="columns">
					<div field="fileName" width="260" headerAlign="center" align="center" allowSort="false" renderer="onActionRenderer">文件名称</div>
					<div field="fileExtension" width="120" headerAlign="center" align="center" allowSort="false" >文件后缀</div>
					<div field="fileSize" width="120" headerAlign="center" align="center" allowSort="false">文件大小(kb)</div>
					<div field="fileUpTime" width="160" headerAlign="center" align="center" allowSort="false" dateFormat="yyyy-MM-dd HH:mm:ss">上传时间</div>
					<div field="fileDownloadNo" width="120" headerAlign="center" align="center" allowSort="false" >下载次数</div>
<!--					<div field="fileRemark" width="120" headerAlign="center" align="center" allowSort="false">文件备注</div>-->
					<div field="upUserName" width="160" headerAlign="center" align="center" allowSort="false">上传人</div>

				</div>
			</div>
		</div>
	</div>
</div>

    <script type="text/javascript">
		txkui.parse();
		diqujazai();
    	var moduleUlr="cqzd/basepatient/";
        var form = new mini.Form("diacrisis_form");
		var existingChild_grid = mini.get("existingChild_grid");
		var live_grid = mini.get("live_grid");
		var assay_grid = mini.get("assay_grid");
		var fetus_grid = mini.get("fetus_grid");
		var fetusDetail_grid = mini.get("fetusDetail_grid");
		var file_grid = mini.get("file_grid");


		//设置表单元素只读
		form.setEnabled(false);
		mini.get("patientRaceId").setData(nation_data);
		function onActionRenderer(e) {
			var row=e.row;
			var aa = row.fileName;
			var s =  '<a href="/cqzd/do/diacfile/getFileByCode/' + row.fileCode + '">' + aa + '</a>';
			return s;
			
		}
		function SetData(dataP) {
			//跨页面传递的数据对象，克隆后才可以安全使用
			var data = mini.clone(dataP);
			var result=data.data;
			form.setData(result.tblDiacrisisInfo);
			existingChild_grid.setData(result.existingChild);
			live_grid.setData(result.patientlive);
			assay_grid.setData(result.diacrisisAssay);
			fetus_grid.setData(result.diacrisisFetus);
            file_grid.setData(result.files);
			var ll=mini.get("transferProvinceId");
			onDeptChanged(mini.get("transferProvinceId"));
			onpositionChange(mini.get("transferCityId"));
		}

		function fetusGridOnclick(e){
			var row = e.row;
			fetusDetail_grid.setData(row.fetusDetail);
		}

		function onIsyouwubigu(e){
			if(e.value==1){
				return "有"
			}else{
				return "无"
			}
		}

		 function diqujazai() {
			var sheng = [];
			for (var s = 0; s < dqdatas.length; s++) {
				sheng.push({ "id": s, "name": dqdatas[s].name });
			}
			mini.get("transferProvinceId").setData(sheng);
		}

		var shiindex = 0;
		function onDeptChanged(el) {
			var shidata = [];
			shiindex = el.value;
			for (var i = 0; i < dqdatas[el.value].city.length; i++) {
				var id = i;
				var name = dqdatas[el.value].city[i].name;
				shidata.push({ "id": id, "name": name })
			}
			mini.get("transferCityId").setData(shidata);

		}

		function onpositionChange(el) {
			var xiandata = [];
			for (var i = 0; i < dqdatas[shiindex].city[el.value].area.length; i++) {
				var id = shiindex + "" + el.value + "" + i;
				var name = dqdatas[shiindex].city[el.value].area[i];
				xiandata.push({ "id": id, "name": name })
			}
			mini.get("transferCountyId").setData(xiandata)
		}

		function renderSex(e){
			return txkui.getDictText("CQ_BASE_SEX",e.value);
		}

    </script>
</body>
</html>